package com.zbkj.crmeb.chant.service;

import com.common.CommonPage;
import com.crmeb.core.common.CommonResult;
import com.common.PageParamRequest;
import com.zbkj.crmeb.chant.model.MerchantAddress;
import com.baomidou.mybatisplus.extension.service.IService;
import com.zbkj.crmeb.chant.request.EnableTakeAddressRequest;
import com.zbkj.crmeb.chant.request.SaveTakeAddressRequest;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author wuzp
 * @since 2021-10-27
 */
public interface MerchantAddressService extends IService<MerchantAddress> {

    /**
     * 新增/编辑自提地址
     * @param request
     * @param merId
     * @return
     */
    CommonResult<String> saveTakeAddress(SaveTakeAddressRequest request, Integer merId,Integer type);

    /**
     * 启用/关闭自提地址
     * @param request
     * @param merId
     * @return
     */
    CommonResult<String> enableTakeAddress(EnableTakeAddressRequest request, Integer merId);

    /**
     * 删除自提地址
     * @param id
     * @param merId
     * @return
     */
    CommonResult<String> deleteTakeAddress(Integer id, Integer merId,Integer type);

    /**
     * 自提地址列表
     * @param request
     * @param merId
     * @return
     */
    List<MerchantAddress> getTakeAddressList(PageParamRequest request, Integer merId,Integer type);

}
